package com.apobates.jforum2.threads.stub.vo;

import java.io.Serializable;

/**
 * 话题的标签
 */
public class ThreadsTagVo implements Serializable{
    //话题标签ID
    private long id;
    //话题ID
    private long threads;
    //标签名/词语
    private String word;
    //频率
    private int rates;

    public ThreadsTagVo() {
    }

    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public long getThreads() {
        return threads;
    }

    public void setThreads(long threads) {
        this.threads = threads;
    }

    public String getWord() {
        return word;
    }

    public void setWord(String word) {
        this.word = word;
    }

    public int getRates() {
        return rates;
    }

    public void setRates(int rates) {
        this.rates = rates;
    }
    
    public static ThreadsTagVo empty(String tagname, long topicId){
        ThreadsTagVo ttv = new ThreadsTagVo();
        //话题标签ID
        ttv.setId(0L);
        //话题ID
        ttv.setThreads(topicId);
        //标签名/词语
        ttv.setWord(tagname);
        //频率
        ttv.setRates(-1);
        return ttv;
    }
}